
      Event.observe(window, 'load', init, false);
   
      function init() {
   
          Field.focus('searchbox');
    
          Event.observe('searchbox', 'keyup', doSearch, false);
      }
      
      function doSearch(u)
      {
          var url = u+'index.php';
 
          var pars = 'action=retrieveposts&keywords='+$F('searchbox');
 
          var target = 'retrieve';
 
          var myAjax = new Ajax.Updater(target, url, {method: 'get', parameters: pars});
      }
      
      function setAlbum(url)
      {
          var pars = 'action=setalbum&albumid='+$F('albums');
 
          var target = ' ';
 
          var myAjax = new Ajax.Updater(target, url, {method: 'post', parameters: pars});
      }